package com.ruibang.glass.equipment.entity.device;

import com.alibaba.excel.annotation.ExcelIgnore;
import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.teaming.cloud.framework2.common.pojo.BaseEntity;
import com.teaming.cloud.framework2.common.tools.LocalDateTimeStringConverter;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.util.Date;
import java.util.List;

@Data
@ApiModel
@TableName(value = "g_equipment_instrument_register")
@ExcelIgnoreUnannotated
/**
 * 锅炉
 */
public class InstrumentRegister extends BaseEntity implements Serializable {
    @ApiModelProperty(value = "主键ID")
    @TableId(value = "id", type = IdType.ASSIGN_ID)
    @ExcelProperty(value = {"id"}, index = 1)
    private String id;
    @ApiModelProperty(value = "区域")
    @ExcelProperty(value = {"区域"}, index = 2)
    private String area;
    @ApiModelProperty(value = "区域名称")
    private String areaName;
    @ApiModelProperty(value = "编号")
    @ExcelProperty(value = {"编号"}, index = 3)
    private String number;
    @ApiModelProperty(value = "名称")
    @ExcelProperty(value = {"名称"}, index = 4)
    private String name;
    @ApiModelProperty(value = "类型")
    @ExcelProperty(value = {"类型"}, index = 5)
    private String type;
    @ApiModelProperty(value = "等级")
    @ExcelProperty(value = {"等级"}, index = 6)

    private String level;
    @ApiModelProperty(value = "校准日期")
    @ExcelProperty(value = {"校准日期"}, index = 7, converter = LocalDateTimeStringConverter.class)
    @JsonFormat(pattern = "yyyy-MM-dd")
    @JSONField(format = "yyyy-MM-dd")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date calibrationDate;
    @ApiModelProperty(value = "校准周期")
    @ExcelProperty(value = {"校准周期"}, index = 8)
    private Integer calibrationPeriod;
    @ApiModelProperty(value = "单位")
    @ExcelProperty(value = {"单位"}, index = 9)
    private String unit;
    @ApiModelProperty(value = "负责人")
    @ExcelProperty(value = {"负责人"}, index = 10)
    private String responsiblePerson;

    @ApiModelProperty(value = "负责人")
    @ExcelIgnore
    private String responsiblePersonId;

    @ApiModelProperty(value = "状态")
    @ExcelProperty(value = {"状态"}, index = 11)
    private String status;

    @ApiModelProperty(value = "校验状态")
    @ExcelIgnore
    private String removeStatus;


    @ApiModelProperty(value = "校验状态")
    @ExcelIgnore
    private String colorStatus;

    @TableField(exist = false)
    @ExcelIgnore
    private List<String> ids;
    @ApiModelProperty(value = "是否删除(1：是 0：否)")
    @TableLogic
    private String isDelete;

}
